const routes = [
  {
    path: '/login',
    title: '登录',
    component: '@/pages/login',
  },
  {
    path: '/',
    title: '首页',
    exact: false,
    component: '@/layouts',
    routes: [
      {
        path: '/',
        title: '首页',
        component: '@/pages/home',
        name: 'home',
        icon: 'iconhome',
      },
      {
        path: '/table',
        title: '表格',
        name: 'table',
        icon: 'iconbiaodanzujian-biaoge',
        routes: [
          {
            path: '/table/user/list',
            title: '用户管理',
            component: '@/pages/user',
            name: 'user-list',
          },
          {
            path: '/table/edit-table',
            title: '可编辑表格',
            component: '@/pages/edit-table',
            name: 'table-edit',
          },
          {
            path: '/table/drag-table',
            title: '可拖拽表格',
            component: '@/pages/drag-table',
            name: 'table-drag',
          },
        ],
      },
      {
        path: '/trag',
        title: '拖拽',
        component: '@/pages/trag',
        name: 'drag',
        icon: 'iconfile',
      },
      {
        path: '/excel',
        title: '导出excel',
        component: '@/pages/excel',
        name: 'excel',
        icon: 'iconfile-excel',
      },
      {
        path: '/test',
        title: '测试',
        component: '@/pages/test',
        name: 'test',
        icon: 'iconfile',
      },
      {
        path: '/upload',
        title: '上传',
        component: '@/pages/upload',
        name: 'upload',
        icon: 'iconfile',
      },
      {
        path: '/editor',
        title: '编辑器',
        name: 'editor',
        icon: 'iconfile',
        routes: [
          {
            path: '/editor/markdown',
            title: 'Markdown编辑器',
            component: '@/pages/editor/markdown',
            name: 'markdown',
          },
          {
            path: '/editor/Editor',
            title: 'Markdown编辑器',
            component: '@/pages/editor/Editor',
            name: 'markdown',
          },
        ],
      },
    ],
  },
];

export default routes;
